public class Test {
    public static void main(String[] args) {
        MyBinaryTree myBinaryTree=new MyBinaryTree();
        MyBinaryTree.TreeNode root=myBinaryTree.creatTree();

        //查找二叉树中是否包含值为key的节点
        System.out.println(myBinaryTree.find(root,'A').val);
        System.out.println("**********************************");
        //前序遍历
        myBinaryTree.preOrder(root);
        System.out.println();
        System.out.println("**********************************");
        //中序遍历
        myBinaryTree.inOrder(root);
        System.out.println();
        System.out.println("**********************************");
        //后序遍历
        myBinaryTree.postOrder(root);
        System.out.println();
        System.out.println("**********************************");
        //获取节点个数
        System.out.print(myBinaryTree.getSize(root));
        System.out.println();
        System.out.println("**********************************");
        //获取叶子节点个数
        System.out.print(myBinaryTree.getLeafNodeCount(root));
        System.out.println();
        System.out.println("**********************************");
        //获取第k层节点个数
        System.out.print(myBinaryTree.getKthLevelNodeCount(root,3));
        System.out.println();
        System.out.println("**********************************");
        //获取二叉树的深度
        System.out.print(myBinaryTree.getHight(root));
        System.out.println();

    }
}